package com.bone.order.service.impl;

import java.util.List;
import java.util.Map;

import com.bone.order.dao.OrdOrderAmountApplyDAO;
import com.bone.order.po.OrdOrderAmountApply;
import com.bone.order.service.OrderAmountService;
import com.bone.page.Page;

public class OrderAmountServiceImpl implements OrderAmountService{

	
	private OrdOrderAmountApplyDAO orderAmountDAO;
	
	 
	/**
	 * 取符合查询条件的数据.
	 * @param parameter
	 * @return
	 */
	public Page<OrdOrderAmountApply> queryOrderAmountPageByParam(Map<String, Object> parameter,
			int pageSize, int page) {
		Page pageConfig = Page.page(pageSize, page);
		return this.orderAmountDAO.queryOrderPageByParam(parameter, pageConfig);
	}
	
	/**
	 * 取符合查询条件的数据根据订单ID.
	 * @param parameter
	 * @return
	 */
	public List<OrdOrderAmountApply> queryOrderAmountByOrderId(Long orderId) {
		 return this.orderAmountDAO.queryOrderAmountListByOrderId(orderId);
	}
	
	/**
	 * 根据主键取相应的订单修改信息.
	 * @param amountApplyId
	 * @return
	 */
	public OrdOrderAmountApply queryOrderAmountById(Long amountApplyId){
		return this.orderAmountDAO.queryOrderAmountApplyById(amountApplyId);
	}
	
	

	public OrdOrderAmountApplyDAO getOrderAmountDAO() {
		return orderAmountDAO;
	}

	public void setOrderAmountDAO(OrdOrderAmountApplyDAO orderAmountDAO) {
		this.orderAmountDAO = orderAmountDAO;
	}
 
}
